import request from "@/utils/request";

// 查询大纸规格列表
export function listSpecs(query) {
  return request({
    url: "/paperSpecs/list",
    method: "get",
    params: query,
  });
}

// 查询大纸规格详细
export function getSpecs(id) {
  return request({
    url: "/paperSpecs/" + id,
    method: "get",
  });
}

// 新增大纸规格
export function addSpecs(data) {
  return request({
    url: "/paperSpecs",
    method: "post",
    data: data,
  });
}

// 修改大纸规格
export function updateSpecs(data) {
  return request({
    url: "/paperSpecs",
    method: "put",
    data: data,
  });
}

// 删除大纸规格
export function delSpecs(id) {
  return request({
    url: "/paperSpecs/" + id,
    method: "delete",
  });
}

// 获取纸张级联下拉数据
export function getPaperList(name) {
  return request({
    url: "/paperSpecs/getPaperList",
    method: "get",
  });
}
